The present invention relates to a data communication method and apparatus which perform the communications of data among processors, such as terminals and computers.
With the spread of private decentralized processing, a data communication system in which a large number of terminals and computers communicate with one another has come into wide use.
A data communication system, as shown in FIG. 1 has heretofore been known (Japanese Laid-open Patent Application No. 51-114804).
Using a coaxial cable 101 as a transmission line, the signals of the coaxial cable 101 are led to a terminal 105 and a computer 106 through transceivers 102, signal lines 103 and connectors 104, whereby data communications are carried out between the terminal 105 and the computer 106.
FIG. 2 shows the interface between the transceiver and the terminal or computer (hereinbelow, termed "processor" or data treating device) in FIG. 1. Referring to FIG. 2, a carrier sensing line 103-1 becomes "1" when a transceiver on the coaxial cable 101, not corresponding to the particular processor, is sending data, and it becomes "0" when not. A contention detecting line 103-2 becomes "1" when, during the data sending of the processor 105, a transceiver not corresponding to the particular processor has simultaneously sent data, and it becomes "0" when not. Using a data sending line 103-3, the processor 105 sends data. In addition, the processor 105 receives data by the use of a data receiving line 103-4.
With this interface, the prior-art system transmits data as described below.
The processor 105 starts sending data through the data sending line 103-3, subject to the carrier sensing line 103-1 being "0". The data is delivered to the coaxial cable 101 by the transceiver 102. The data is transmitted along the coaxial cable 101 with a propagation delay, and is received by a transceiver not corresponding to the particular processor. This transceiver brings the carrier sensing line to "1", to indicate that the coaxial cable 101 is occupied. However, in a case where, even after the transceiver 102 has started sending the data, the carrier sensing line of a transceiver not corresponding to the particular processor is still "0" on account of the propagation delay, the processor connected to this transceiver might start sending data. In this case, the transceiver 102 detects a contention and brings the contention detecting line 103-2 to "1". When the contention detecting line 103-2 has become "1", the processor 105 interrupts the sending of the data. Upon lapse of a time generated with a random number, it starts the sending of the same data again after detecting that the carrier sensing line is "0".
Since such system does not include means for acknowledging that the data sent from the transceiver has arrived at the transceiver in an intended receiving station without any error, the processor of the intended receiving station needs to send acknowledge data to the processor of the sending station by the use of the same transmission line in order to communicate the correct arrival of the data. This has led to the problem that the possibility of a contention due to the acknowledge data increases.
In addition, the processor of the intended receiving station sends the acknowledge data after having received all the data, and the processor on the sending side can acknowledge the arrival of the data at the intended receiving station upon receiving the acknowledge data. This has led to the problem that a delay corresponding to an acknowledge data receiving time extends from the end of the sending to the arrival of the acknowledgement.
Moreover, the sending side processor usually monitors the reception of the acknowledge data with a timer after having sent the data. In a case where the data has not properly arrived at the intended receiving station on account of a transmission error and where the acknowledge data is not received back, the processor re-sends the data after a time-out. Herein, a timer value needs to be longer than the period of time in which the acknowledge data is properly received after the end of the sending. This has led to the problem that, after the development of the transmission error, a long time is taken before the re-sending can be started.